from bs4 import BeautifulSoup
import douban
html = ''
names = []
directors=[]
actors = []
years = []
countries = []
types = []
#取图片地址
srcs = []

with open('top250/src1.html','r',encoding='utf-8') as f:
    html = f.read() #把所有内容读取到html中
# print(html)
bs = BeautifulSoup(html,'lxml')
# print(bs.select('div.item div.hd span.title:nth-child(1)'))
douban.setTop250Data(bs,names,directors,actors,years,countries,types,srcs)


print(srcs)
print(directors)
print(actors)
print(years)
print(countries)
print(types)